// import * from '@/until/validate'

export const tableOption = {
  border: true,
  index: true,
  indexLabel: '序号',
  stripe: true,
  menuAlign: 'center',
  align: 'center',
  editBtn: false,
  delBtn: false,
  addBtn: false,
  searchBtn: false,
  columnBtn: false,
  refreshBtn: false,
  labelWidth: 120,
  column: [
    //  {
    //   label: 'Id',
    //   prop: 'id',
    //   addVisdiplay: false,
    //   editVisdiplay: false
    // },
    {
      label: '商铺名称',
      prop: 'shopName',
      search: true,
      rules: [{
        required: true,
        message: '请输入商铺名称'
      },
        {
          min: 2,
          max: 100,
          message: '长度在 2 到 100 个字符',
          trigger: 'blur'
        }]
    },
    {
      label: '联系人姓名',
      prop: 'shopContactName',
      search: true,
      rules: [{
        required: true,
        message: '请输入联系人姓名'
      },
        {
          min: 1,
          max: 20,
          message: '长度在 1 到 20 个字符',
          trigger: 'blur'
        }]
    },
    {
      label: '联系人电话',
      prop: 'shopContactPhone',
      search: true,
      type: 'phone',
      rules: [{
        required: true,
        message: '请输入联系人电话'
      },
        {
          min: 7,
          max: 15,
          message: '长度在 7 到 15 个字符',
          trigger: 'blur'
        }]
    },
    {
      label: '地址',
      prop: 'shopAddress',
      rules: [{
        required: true,
        message: '请输入地址'
      },
        {
          min: 1,
          max: 200,
          message: '长度在 1 到 200 个字符',
          trigger: 'blur'
        }]
    },
    {
      label: '服务范围中心点',
      prop: 'map',
      hide: true,
      formsolt: true,
      slot: true,
      span: 24,
      rules: [{
        // required: true,
        // message: '请输入地址'
      }]
    },
    {
      label: '开始营业时间',
      prop: 'openingHours',
      visdiplay: false
    },
    {
      label: '结束营业时间',
      prop: 'closingHours',
      visdiplay: false,
    },
    {
      label: '营业时间',
      prop: 'shopHours',
      solt: true,
      formsolt: true,
      overHidden: true,
      hidden: true,
      hide: true,
      rules: [{
        required: true,
        message: '请输入营业时间'
      }]
    },
    {
      label: '服务范围(km)',
      prop: 'radiationRange',
      // type: 'number',
      precision: 2,
      span: 12,
      // mock: {
      //   type: 'number',
      //   min: 0,
      //   precision:2,
      //   max:20,
      // },
      rules: [{
        required: true,
        message: '请填写商铺服务范围',
      }]
    },
    {
      label: '经度',
      addDisabled: true,
      editDisabled: true,
      prop: 'shopLongitude',
      rules: [{
        required: true,
        message: '请输入经度'
      }]
    },
    {
      label: '纬度',
      addDisabled: true,
      editDisabled: true,
      prop: 'shopLatitude',
      rules: [{
        required: true,
        message: '请输入纬度'
      }]
    },
    {
      label: '入驻时间',
      prop: 'shopEnterTime',
      addVisdiplay: false,
      editVisdiplay: false
    },
    {
      label: '排序',
      prop: 'shopSort',
      type: 'number',
      rules: [{
        required: true,
        message: '请输入排序',
        trigger: 'blur'
      }]
    },
    {
      label: '优惠券二维码',
      span: 20,
      width: '200',
      visdiplay: false,
      addDisabled: true,
      editDisabled: true,
      prop: 'couponCodePath',
      solt: true,
      formsolt: true,
    },
    {
      label: '服务类型',
      span: 20,
      width: '200',
      prop: 'serviceTypeId',
      hide: true,
      slot: true,
      formsolt: true,
      rules: [{
        required: true,
        message: '请选择服务类型',
        trigger: 'change'
      }]
    }
  ]
}
